package library.dao;

import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.Statement;

public abstract class ConnectedDao {

    protected Connection connection;

    public ConnectedDao(Connection connection) {
        this.connection = connection;
    }

    final protected void close(ResultSet resultSet, Statement statement) {
        try {
            resultSet.close();
        } catch (Exception e) {
        }
        try {
            statement.close();
        } catch (Exception e) {
            System.err.print(e.toString());
        }
    }
}
